<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <h:head>
        <title><h:outputText value="#{bundle.AppName}"></h:outputText></title>
        <p:growl widgetVar="growl" life="3000" />

    </h:head>
    <h:body>
        <h:form> 
            <p:graphicImage value="resources/images/Library2.jpg" style="z-index:-1; min-height: 100%; min-width: 1024px; width: 100%; height: auto;position: fixed; top: 0;  left: 0;" />
            <p:dialog header="Ingreso a MaRoY Library System" rendered="true" visible="true" resizable="false" closable="false" hideEffect="puff" showEffect="shake">
                <h:panelGroup id="display">
                    <p:panelGrid columns="2" >
                        <h:outputLabel for="input_username" value="Usuario"/>
                        <p:inputText id="input_username" value="#{loginBean.username}" maxlength="45" />
                        <h:outputLabel for="input_password" value="Contraseña"/>
                        <p:password id="input_password" value="#{loginBean.password}" maxlength="45" />
                        <h:outputLabel value=" "/>
                        <p:splitButton value="Iniciar Session" action="#{loginBean.login()}"  ajax="false" update="growl" icon="ui-icon-key">  
                            <p:separator />  
                            <p:menuitem value="Crear Cuenta" url="/faces/register.xhtml" icon="ui-icon-extlink"/>  
                        </p:splitButton>  
                    </p:panelGrid>
                </h:panelGroup>
            </p:dialog>
        </h:form>
    </h:body>
</html>